<!DOCTYPE html>
<!-- saved from url=(0016)http://localhost -->
<html>
  <head>
    <meta charset="utf-8"/>
    <meta content="IE=edge" http-equiv="X-UA-Compatible"/>
    <title>Index</title>
    <style>
        body{
            margin: 0;
        }
        #content-info{
            width: auto;
            margin: 0 auto;
            text-align: center;
        }
        #author-info{
            white-space: nowrap;
            text-overflow: ellipsis;
            overflow: hidden;
        }
        #title{
            text-overflow: ellipsis;
            white-space: nowrap;
            overflow: hidden;
            padding-top: 10px;
            margin-bottom: 2px;
            font-size: 34px;
            color: #505050;
        }
        .text{
            white-space:nowrap;
            text-overflow: ellipsis;
            display: inline-block;
            margin-right: 20px;
            margin-bottom: 2px;
            font-size: 20px;
            color: #8c8c8c;
        }
        #navBar{
            width: auto;
            height: auto;
            position: fixed;
            right:0;
            bottom: 0;
            background-color: #f0f3f4;
            overflow-y: auto;
            text-align: center;
        }
        #svg-container{
            width: 100%;
            overflow-x: scroll;
            min-width: 0px;
            margin: 0 10px;
            overflow: visible;
            position: relative;
        }
        #nav-thumbs{
            overflow-y: scroll;
            padding: 0 5px;
        }
        .nav-thumb{
            position: relative;
            margin: 10px auto;
        }
        .nav-thumb >p{
            text-align: center;
            font-size: 12px;
            margin: 4px 0 0 0;
        }
        .nav-thumb >div{
            position: relative;
            display: inline-block;
            border: 1px solid #c6cfd5;
        }
        .nav-thumb img{
            display: block;
        }
        #main-content{
            bottom: 0;
            left: 0;
            right: 0;
            background-color: #d0cfd8;
            display: flex;
            height: auto;
            flex-flow: row wrap;
            text-align:center;
        }
        #svg-container >svg{
            overflow: visible;
            display: block;
            margin:5px auto;
            margin-bottom: 5px;
        }
        #copyright{
            bottom: 0;
            left: 50%;
            margin: 5px auto;
            font-size: 16px;
            color: #515151;
        }
        #copyright >a{
            text-decoration: none;
            color: #77C;
        }
        .number{
            position: absolute;
            top:0;
            left:0;
            border-top:22px solid #08a1ef;
            border-right: 22px solid transparent;
        }
        .pagenum{
            font-size: 12px;
            color: #fff;
            position: absolute;
            top: -23px;
            left: 2px;
        }
            #navBar::-webkit-scrollbar{
            width: 8px;
            background-color: #f5f5f5;
        }
            #navBar::-webkit-scrollbar-track{
            -webkit-box-shadow: inset 0 0 4px rgba(0,0,0,.3);
            border-radius: 8px;
            background-color: #fff;
        }
            #navBar::-webkit-scrollbar-thumb{
            border-radius: 8px;
            -webkit-box-shadow: inset 0 0 4px rgba(0,0,0,.3);
            background-color: #6b6b70;
        }
        #navBar::-webkit-scrollbar-thumb:hover{
            background-color: #4a4a4f;
        }
</style>
  </head>
  <body>
    <div id="main-area">
      <div id="content-info">
        <div id="content-info">
          <div id="title">Index</div>
        </div>
        <div id="author-info">
          <div class="text" id="author-name">RUWU</div>
          <div class="text" id="share-time">2024-03-05</div>
        </div>
      </div>
      <div id="main-content">
        <div id="svg-container"><svg width="1761" ed:hSpacing="30" preserveAspectRadio="xMinYMin meet" xmlns="http://www.w3.org/2000/svg" height="826" xmlns:ev="http://www.w3.org/2001/xml-events" id="page0" viewBox="0 0 1761 826" xmlns:xlink="http://www.w3.org/1999/xlink" ed:vSpacing="30" xmlns:ed="https://www.edrawsoft.com/xml/2017/SVGExtensions/" ed:name="画布 1">
    <style type="text/css"><![CDATA[
g[ed\:togtopicid],g[ed\:hyperlink],g[ed\:comment],g[ed\:note] {cursor:pointer;}
g[id] {-moz-user-select: none;-ms-user-select: none;user-select: none;}
svg text::selection,svg tspan::selection{background-color: #4285f4;color: #ffffff;fill: #ffffff;}
.st45 {fill:#454545;font-family:Times New Roman;font-size:23pt;font-weight:bold}
.st48 {fill:#454545;font-family:华文楷体;font-size:13pt}
.st46 {fill:#454545;font-family:华文楷体;font-size:15pt}
.st47 {fill:#ffffff;font-family:华文楷体;font-size:13pt;font-weight:bold}
]]></style>
    <defs/>
    <rect width="1761" height="826" x="0" y="0" fill="#fbfcfb"/>
    <g ed:fromid="122" transform="matrix(1,0,0,1,1272.77,101.53)" ed:toid="270" ed:type="relation" id="271">
        <path d="M-127,42C-125.9,15.7,-66.2,-68.8,127,-42" fill="none"/>
        <path d="M-127,42C-125.9,16,-67.9,-66.4,118.8,-43.1" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
        <path d="M127,-42L118,-48.9C118.7,-47.1,119,-45.1,118.8,-43.1C118.5,-41,117.7,-39.2,116.5,-37.7L127,-42" stroke-width="1" stroke="#a98ae7" fill="#a98ae7" stroke-linecap="round"/>
    </g>
    <g ed:fromid="147" transform="matrix(1,0,0,1,1357.62,256.87)" ed:toid="272" ed:type="relation" id="273">
        <path d="M-205.4,19.5C-189.1,-23.5,77.6,-35.5,205.4,-19.5" fill="none"/>
        <path d="M-205.4,19.5C-189.4,-22.6,66.5,-35,197.1,-20.5" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
        <path d="M205.4,-19.5L196.3,-26.3C197.1,-24.5,197.4,-22.5,197.1,-20.5C196.9,-18.4,196.1,-16.6,195,-15.1L205.4,-19.5" stroke-width="1" stroke="#a98ae7" fill="#a98ae7" stroke-linecap="round"/>
    </g>
    <g ed:fromid="139" transform="matrix(1,0,0,1,1411.94,405.55)" ed:toid="274" ed:type="relation" id="275">
        <path d="M-194.1,39.1C-156.4,-17,9.7,-62.7,194.1,-39.1" fill="none"/>
        <path d="M-194.1,39.1C-156.9,-16.1,4.8,-61.3,185.8,-40.1" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
        <path d="M194.1,-39.1L185,-45.9C185.8,-44.2,186.1,-42.2,185.8,-40.1C185.6,-38.1,184.8,-36.2,183.6,-34.7L194.1,-39.1" stroke-width="1" stroke="#a98ae7" fill="#a98ae7" stroke-linecap="round"/>
    </g>
    <g ed:fromid="145" transform="matrix(1,0,0,1,1405.51,593.06)" ed:toid="298" ed:type="relation" id="299">
        <path d="M-200.5,37.7C-81.1,-38.6,16.8,-29.2,200.5,-37.7" fill="none"/>
        <path d="M-200.5,37.7C-82.9,-37.5,13.8,-29.5,192.2,-37.3" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
        <path d="M200.5,-37.7L190.5,-42.9C191.5,-41.3,192.1,-39.3,192.2,-37.3C192.3,-35.2,191.8,-33.3,191,-31.6L200.5,-37.7" stroke-width="1" stroke="#a98ae7" fill="#a98ae7" stroke-linecap="round"/>
    </g>
    <path ed:tosuperid="122" transform="matrix(1,0,0,1,941.7,303.68)" id="123" ed:parentid="101" d="M18.3,-65.2C17.4,-63.6,17.8,-62,19,-61.3C20.2,-60.6,21.8,-61.1,22.7,-62.7C23.8,-64.7,24.9,-66.7,26.1,-68.7C27.3,-70.7,28.5,-72.6,29.7,-74.6C31,-76.5,32.3,-78.4,33.6,-80.3C34.9,-82.2,36.3,-84,37.7,-85.9C39.1,-87.7,40.6,-89.4,42.1,-91.2C43.6,-92.9,45.1,-94.6,46.7,-96.2C48.4,-97.9,50,-99.5,51.7,-101C53.5,-102.5,55.2,-103.9,57.1,-105.3C58.9,-106.7,60.8,-108,62.7,-109.2C64.7,-110.4,66.7,-111.6,68.7,-112.6C70.8,-113.7,72.9,-114.6,75,-115.5C77.1,-116.3,79.3,-117.1,81.5,-117.8C83.7,-118.4,86,-119,88.2,-119.5C90.4,-120,92.6,-120.3,95.1,-120.6C97.5,-120.9,100.3,-121.1,102,-121.2C103.7,-121.3,104.2,-121.3,104.8,-121.3C105.2,-121.3,105.4,-121.5,105.4,-121.8C105.4,-122.1,105.2,-122.3,104.8,-122.3C104.2,-122.3,103.7,-122.3,102,-122.3C100.3,-122.3,97.5,-122.2,94.9,-122C92.4,-121.8,90.2,-121.5,87.9,-121.1C85.7,-120.7,83.3,-120.2,81,-119.6C78.7,-119,76.5,-118.3,74.2,-117.5C72,-116.7,69.8,-115.8,67.7,-114.8C65.5,-113.8,63.4,-112.7,61.4,-111.5C59.3,-110.3,57.3,-109,55.4,-107.7C53.4,-106.3,51.5,-104.9,49.7,-103.4C47.8,-101.9,46.1,-100.3,44.3,-98.7C42.6,-97.1,40.9,-95.4,39.3,-93.7C37.7,-91.9,36.1,-90.2,34.6,-88.3C33.1,-86.5,31.6,-84.7,30.2,-82.8C28.8,-80.9,27.4,-79,26,-77.1C24.7,-75.1,23.3,-73.2,22.1,-71.2C20.8,-69.2,19.6,-67.2,18.3,-65.2z" stroke="#ff7575" stroke-linejoin="round" fill="#ff7575" stroke-linecap="round"/>
    <path ed:tosuperid="139" transform="matrix(1,0,0,1,941.7,454.26)" id="140" ed:parentid="101" d="M42.7,14.2C41,13.6,39.4,14.3,39,15.6C38.5,16.8,39.2,18.4,40.9,18.9C43.2,19.6,45.4,20.4,47.7,21C49.9,21.7,52.2,22.4,54.5,23C56.7,23.6,59,24.2,61.3,24.7C63.6,25.3,65.9,25.8,68.2,26.2C70.5,26.7,72.9,27.1,75.2,27.4C77.5,27.8,79.8,28.1,82.2,28.4C84.5,28.6,86.9,28.8,89.2,29C91.5,29.2,93.7,29.3,96.2,29.3C98.8,29.4,101.8,29.3,103.3,29.3C104.8,29.3,104.8,29.3,104.8,29.3C105.1,29.1,105.4,29.1,105.4,28.8C105.4,28.5,105.1,28.1,104.8,28.3C104.8,28.3,104.8,28.3,103.3,28.2C101.8,28.2,98.9,28,96.3,27.8C93.8,27.6,91.6,27.3,89.4,27C87.2,26.8,84.8,26.4,82.5,26C80.2,25.6,78,25.2,75.7,24.7C73.5,24.2,71.2,23.6,69,23C66.7,22.5,64.5,21.8,62.3,21.2C60.1,20.5,57.9,19.8,55.7,19C53.5,18.3,51.3,17.5,49.1,16.7C47,15.9,44.8,15.1,42.7,14.2z" stroke="#ffcd55" stroke-linejoin="round" fill="#ffcd55" stroke-linecap="round"/>
    <path ed:tosuperid="145" transform="matrix(1,0,0,1,941.7,547.27)" id="146" ed:parentid="101" d="M22.7,62.7C21.8,61.1,20.2,60.6,19,61.3C17.8,62,17.4,63.6,18.3,65.2C19.6,67.2,20.8,69.2,22.1,71.2C23.3,73.2,24.7,75.1,26,77.1C27.4,79,28.8,80.9,30.2,82.8C31.6,84.7,33.1,86.5,34.6,88.3C36.1,90.2,37.7,91.9,39.3,93.7C40.9,95.4,42.6,97.1,44.3,98.7C46.1,100.3,47.8,101.9,49.7,103.4C51.5,104.9,53.4,106.3,55.4,107.7C57.3,109,59.3,110.3,61.4,111.5C63.4,112.7,65.5,113.8,67.7,114.8C69.8,115.8,72,116.7,74.2,117.5C76.5,118.3,78.7,119,81,119.6C83.3,120.2,85.7,120.7,87.9,121.1C90.2,121.5,92.4,121.8,94.9,122C97.5,122.2,100.3,122.3,102,122.3C103.7,122.3,104.2,122.3,104.8,122.3C105.2,122.3,105.4,122.1,105.4,121.8C105.4,121.5,105.2,121.3,104.8,121.3C104.2,121.3,103.7,121.3,102,121.2C100.3,121.1,97.5,120.9,95.1,120.6C92.6,120.3,90.4,120,88.2,119.5C86,119,83.7,118.4,81.5,117.8C79.3,117.1,77.1,116.3,75,115.5C72.9,114.6,70.8,113.7,68.7,112.6C66.7,111.6,64.7,110.4,62.7,109.2C60.8,108,58.9,106.7,57.1,105.3C55.2,103.9,53.5,102.5,51.7,101C50,99.5,48.4,97.9,46.7,96.2C45.1,94.6,43.6,92.9,42.1,91.2C40.6,89.4,39.1,87.7,37.7,85.9C36.3,84,34.9,82.2,33.6,80.3C32.3,78.4,31,76.5,29.7,74.6C28.5,72.6,27.3,70.7,26.1,68.7C24.9,66.7,23.8,64.7,22.7,62.7z" stroke="#f1a3dc" stroke-linejoin="round" fill="#f1a3dc" stroke-linecap="round"/>
    <path ed:tosuperid="147" transform="matrix(1,0,0,1,941.7,370.11)" id="148" ed:parentid="101" d="M40.4,-37.5C38.9,-36.6,38.5,-34.9,39.3,-33.8C40,-32.6,41.7,-32.3,43.2,-33.3C45.1,-34.6,47,-35.9,48.9,-37.2C50.8,-38.4,52.8,-39.6,54.8,-40.7C56.8,-41.9,58.8,-42.9,60.9,-44C62.9,-45,65,-45.9,67.2,-46.8C69.3,-47.7,71.4,-48.5,73.6,-49.3C75.8,-50,78,-50.7,80.2,-51.3C82.5,-51.9,84.7,-52.4,87,-52.9C89.2,-53.3,91.4,-53.7,93.8,-54C96.2,-54.3,98.9,-54.5,100.7,-54.7C102.6,-54.8,103.7,-54.8,104.8,-54.9C105.2,-54.9,105.4,-55.1,105.4,-55.4C105.4,-55.6,105.2,-55.9,104.8,-55.9C103.7,-55.9,102.6,-55.9,100.7,-55.9C98.8,-55.9,96.1,-55.8,93.6,-55.7C91.2,-55.5,88.9,-55.3,86.6,-54.9C84.3,-54.6,82,-54.2,79.6,-53.7C77.3,-53.3,75,-52.7,72.7,-52.1C70.5,-51.4,68.2,-50.7,66,-49.9C63.7,-49.2,61.5,-48.3,59.3,-47.4C57.1,-46.4,55,-45.5,52.9,-44.4C50.7,-43.4,48.6,-42.3,46.6,-41.1C44.5,-40,42.5,-38.7,40.4,-37.5z" stroke="#5fb7f1" stroke-linejoin="round" fill="#5fb7f1" stroke-linecap="round"/>
    <path ed:tosuperid="246" transform="matrix(1,0,0,1,732.1,263.8)" id="247" ed:parentid="101" d="M4.2,-23.3C4.6,-21.6,6.1,-20.8,7.4,-21.1C8.7,-21.5,9.5,-23,9,-24.7C8.3,-27,7.6,-29.2,7,-31.4C6.3,-33.7,5.6,-35.9,4.9,-38.1C4.2,-40.4,3.5,-42.6,2.8,-44.8C2.1,-47.1,1.3,-49.3,0.6,-51.5C-0.1,-53.7,-0.9,-56,-1.7,-58.2C-2.4,-60.4,-3.2,-62.6,-4,-64.8C-4.8,-67,-5.6,-69.2,-6.4,-71.4C-7.3,-73.6,-8.1,-75.8,-9,-77.9C-9.9,-80.1,-10.8,-82.3,-11.7,-84.5C-12.6,-86.6,-13.5,-88.8,-14.5,-90.9C-15.5,-93,-16.5,-95.2,-17.5,-97.3C-18.5,-99.4,-19.6,-101.5,-20.7,-103.6C-21.8,-105.6,-22.9,-107.7,-24.1,-109.7C-25.3,-111.8,-26.5,-113.8,-27.8,-115.8C-29,-117.8,-30.3,-119.8,-31.7,-121.7C-33,-123.6,-34.4,-125.5,-35.9,-127.4C-37.3,-129.2,-38.8,-131.1,-40.4,-132.8C-41.9,-134.6,-43.5,-136.3,-45.2,-138C-46.9,-139.7,-48.6,-141.3,-50.4,-142.8C-52.2,-144.3,-54.1,-145.8,-56,-147.2C-57.9,-148.6,-59.9,-149.9,-61.9,-151.1C-63.9,-152.3,-66,-153.4,-68.1,-154.4C-70.3,-155.5,-72.4,-156.4,-74.7,-157.2C-76.9,-158,-79.1,-158.7,-81.4,-159.3C-83.7,-160,-86,-160.5,-88.3,-160.9C-90.6,-161.3,-92.7,-161.6,-95.3,-161.8C-97.8,-162,-100.7,-162.1,-102.3,-162.2C-103.9,-162.2,-104.4,-162.2,-104.8,-162.2C-105.2,-162.2,-105.4,-162,-105.4,-161.7C-105.4,-161.4,-105.2,-161.2,-104.8,-161.2C-104.4,-161.2,-104,-161.2,-102.3,-161.1C-100.7,-161,-97.9,-160.9,-95.4,-160.6C-92.9,-160.3,-90.8,-160,-88.5,-159.5C-86.3,-159.1,-84,-158.6,-81.8,-157.9C-79.6,-157.3,-77.4,-156.5,-75.2,-155.7C-73.1,-154.8,-71,-153.9,-68.9,-152.8C-66.9,-151.8,-64.9,-150.7,-62.9,-149.4C-61,-148.2,-59.1,-146.9,-57.2,-145.5C-55.4,-144.1,-53.6,-142.7,-51.9,-141.1C-50.2,-139.6,-48.5,-138,-46.9,-136.3C-45.3,-134.7,-43.8,-133,-42.3,-131.2C-40.8,-129.4,-39.3,-127.6,-38,-125.8C-36.6,-123.9,-35.3,-122,-34,-120.1C-32.7,-118.2,-31.5,-116.2,-30.3,-114.2C-29.1,-112.3,-27.9,-110.3,-26.8,-108.2C-25.7,-106.2,-24.6,-104.1,-23.6,-102.1C-22.6,-100,-21.5,-97.9,-20.6,-95.8C-19.6,-93.7,-18.7,-91.6,-17.7,-89.5C-16.8,-87.3,-15.9,-85.2,-15.1,-83C-14.2,-80.9,-13.4,-78.7,-12.6,-76.6C-11.7,-74.4,-10.9,-72.2,-10.2,-70C-9.4,-67.8,-8.6,-65.6,-7.9,-63.4C-7.1,-61.2,-6.4,-59,-5.7,-56.8C-5,-54.6,-4.3,-52.4,-3.6,-50.2C-2.9,-47.9,-2.2,-45.7,-1.6,-43.5C-0.9,-41.3,-0.3,-39,0.4,-36.8C1,-34.5,1.7,-32.3,2.3,-30.1C2.9,-27.8,3.5,-25.6,4.2,-23.3z" stroke="#a98ae7" stroke-linejoin="round" fill="#a98ae7" stroke-linecap="round"/>
    <path ed:tosuperid="258" transform="matrix(1,0,0,1,732.1,365.68)" id="259" ed:parentid="101" d="M-43.2,-36.8C-41.8,-35.8,-40.1,-36,-39.3,-37.2C-38.6,-38.3,-38.8,-40,-40.4,-40.9C-42.4,-42.2,-44.4,-43.5,-46.4,-44.7C-48.4,-45.9,-50.5,-47.1,-52.6,-48.2C-54.7,-49.3,-56.9,-50.3,-59,-51.3C-61.2,-52.2,-63.4,-53.1,-65.6,-54C-67.8,-54.8,-70.1,-55.5,-72.4,-56.2C-74.6,-56.9,-76.9,-57.5,-79.2,-58C-81.5,-58.5,-83.9,-58.9,-86.2,-59.3C-88.5,-59.6,-90.8,-59.9,-93.2,-60C-95.7,-60.2,-98.3,-60.3,-100.3,-60.3C-102.2,-60.4,-103.5,-60.3,-104.8,-60.3C-105.2,-60.3,-105.4,-60.1,-105.4,-59.8C-105.4,-59.5,-105.2,-59.3,-104.8,-59.3C-103.5,-59.3,-102.2,-59.2,-100.3,-59.1C-98.4,-58.9,-95.8,-58.7,-93.4,-58.4C-91,-58,-88.8,-57.7,-86.6,-57.2C-84.3,-56.7,-82.1,-56.2,-79.8,-55.5C-77.6,-54.9,-75.4,-54.2,-73.3,-53.4C-71.1,-52.6,-69,-51.8,-66.9,-50.9C-64.8,-49.9,-62.7,-48.9,-60.7,-47.9C-58.6,-46.8,-56.6,-45.7,-54.7,-44.5C-52.7,-43.3,-50.7,-42.1,-48.8,-40.8C-47,-39.5,-45.1,-38.2,-43.2,-36.8z" stroke="#fa8556" stroke-linejoin="round" fill="#fa8556" stroke-linecap="round"/>
    <path ed:tosuperid="157" transform="matrix(1,0,0,1,732.1,485.28)" id="158" ed:parentid="101" d="M-40.4,40.9C-38.8,40,-38.6,38.3,-39.3,37.2C-40.1,36,-41.8,35.8,-43.2,36.8C-45.1,38.2,-47,39.5,-48.8,40.8C-50.7,42.1,-52.7,43.3,-54.7,44.5C-56.6,45.7,-58.6,46.8,-60.7,47.9C-62.7,48.9,-64.8,49.9,-66.9,50.9C-69,51.8,-71.1,52.6,-73.3,53.4C-75.4,54.2,-77.6,54.9,-79.8,55.5C-82.1,56.2,-84.3,56.7,-86.6,57.2C-88.8,57.7,-91,58,-93.4,58.4C-95.8,58.7,-98.4,58.9,-100.3,59.1C-102.2,59.2,-103.5,59.3,-104.8,59.3C-105.2,59.3,-105.4,59.5,-105.4,59.8C-105.4,60.1,-105.2,60.3,-104.8,60.3C-103.5,60.3,-102.2,60.4,-100.3,60.3C-98.3,60.3,-95.7,60.2,-93.2,60C-90.8,59.9,-88.5,59.6,-86.2,59.3C-83.9,58.9,-81.5,58.5,-79.2,58C-76.9,57.5,-74.6,56.9,-72.4,56.2C-70.1,55.5,-67.8,54.8,-65.6,54C-63.4,53.1,-61.2,52.2,-59,51.3C-56.9,50.3,-54.7,49.3,-52.6,48.2C-50.5,47.1,-48.4,45.9,-46.4,44.7C-44.4,43.5,-42.4,42.2,-40.4,40.9z" stroke="#80cf70" stroke-linejoin="round" fill="#80cf70" stroke-linecap="round"/>
    <path ed:tosuperid="243" transform="matrix(1,0,0,1,732.1,587.15)" id="244" ed:parentid="101" d="M9,24.7C9.5,23,8.7,21.5,7.4,21.1C6.1,20.8,4.6,21.6,4.2,23.3C3.5,25.6,2.9,27.8,2.3,30.1C1.7,32.3,1,34.5,0.4,36.8C-0.3,39,-0.9,41.3,-1.6,43.5C-2.2,45.7,-2.9,47.9,-3.6,50.2C-4.3,52.4,-5,54.6,-5.7,56.8C-6.4,59,-7.1,61.2,-7.9,63.4C-8.6,65.6,-9.4,67.8,-10.2,70C-10.9,72.2,-11.7,74.4,-12.6,76.6C-13.4,78.7,-14.2,80.9,-15.1,83C-15.9,85.2,-16.8,87.3,-17.7,89.5C-18.7,91.6,-19.6,93.7,-20.6,95.8C-21.5,97.9,-22.6,100,-23.6,102.1C-24.6,104.1,-25.7,106.2,-26.8,108.2C-27.9,110.3,-29.1,112.3,-30.3,114.2C-31.5,116.2,-32.7,118.2,-34,120.1C-35.3,122,-36.6,123.9,-38,125.8C-39.3,127.6,-40.8,129.4,-42.3,131.2C-43.8,133,-45.3,134.7,-46.9,136.3C-48.5,138,-50.2,139.6,-51.9,141.1C-53.6,142.7,-55.4,144.1,-57.2,145.5C-59.1,146.9,-61,148.2,-62.9,149.4C-64.9,150.7,-66.9,151.8,-68.9,152.8C-71,153.9,-73.1,154.8,-75.2,155.7C-77.4,156.5,-79.6,157.3,-81.8,157.9C-84,158.6,-86.3,159.1,-88.5,159.5C-90.8,160,-92.9,160.3,-95.4,160.6C-97.9,160.9,-100.7,161,-102.3,161.1C-104,161.2,-104.4,161.2,-104.8,161.2C-105.2,161.2,-105.4,161.4,-105.4,161.7C-105.4,162,-105.2,162.2,-104.8,162.2C-104.4,162.2,-103.9,162.2,-102.3,162.2C-100.7,162.1,-97.8,162,-95.3,161.8C-92.7,161.6,-90.6,161.3,-88.3,160.9C-86,160.5,-83.7,160,-81.4,159.3C-79.1,158.7,-76.9,158,-74.7,157.2C-72.4,156.4,-70.3,155.5,-68.1,154.4C-66,153.4,-63.9,152.3,-61.9,151.1C-59.9,149.9,-57.9,148.6,-56,147.2C-54.1,145.8,-52.2,144.3,-50.4,142.8C-48.6,141.3,-46.9,139.7,-45.2,138C-43.5,136.3,-41.9,134.6,-40.4,132.8C-38.8,131.1,-37.3,129.2,-35.9,127.4C-34.4,125.5,-33,123.6,-31.7,121.7C-30.3,119.8,-29,117.8,-27.8,115.8C-26.5,113.8,-25.3,111.8,-24.1,109.7C-22.9,107.7,-21.8,105.6,-20.7,103.6C-19.6,101.5,-18.5,99.4,-17.5,97.3C-16.5,95.2,-15.5,93,-14.5,90.9C-13.5,88.8,-12.6,86.6,-11.7,84.5C-10.8,82.3,-9.9,80.1,-9,77.9C-8.1,75.8,-7.3,73.6,-6.4,71.4C-5.6,69.2,-4.8,67,-4,64.8C-3.2,62.6,-2.4,60.4,-1.7,58.2C-0.9,56,-0.1,53.7,0.6,51.5C1.3,49.3,2.1,47.1,2.8,44.8C3.5,42.6,4.2,40.4,4.9,38.1C5.6,35.9,6.3,33.7,7,31.4C7.6,29.2,8.3,27,9,24.7z" stroke="#6cc9e5" stroke-linejoin="round" fill="#6cc9e5" stroke-linecap="round"/>
    <path ed:tosuperid="204" transform="matrix(1,0,0,1,1261.05,164.16)" id="205" ed:parentid="122" d="M-17.5,17.7C0.6,17.7,-2.5,-17.7,17.5,-17.7" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="206" transform="matrix(1,0,0,1,1261.05,181.89)" id="207" ed:parentid="122" d="M-17.5,0C-3.5,0,7,0,17.5,0" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="208" transform="matrix(1,0,0,1,1261.05,199.61)" id="209" ed:parentid="122" d="M-17.5,-17.7C0.6,-17.7,-2.5,17.7,17.5,17.7" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="210" transform="matrix(1,0,0,1,1261.05,297.01)" id="211" ed:parentid="147" d="M-17.5,17.7C0.6,17.7,-2.5,-17.7,17.5,-17.7" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="212" transform="matrix(1,0,0,1,1261.05,314.74)" id="213" ed:parentid="147" d="M-17.5,0C-3.5,0,7,0,17.5,0" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="214" transform="matrix(1,0,0,1,1261.05,332.46)" id="215" ed:parentid="147" d="M-17.5,-17.7C0.6,-17.7,-2.5,17.7,17.5,17.7" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="216" transform="matrix(1,0,0,1,1381.05,447.59)" id="217" ed:parentid="139" d="M-17.6,35.5C4,35.5,-10.5,-35.5,17.5,-35.5" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="218" transform="matrix(1,0,0,1,1381.05,465.31)" id="219" ed:parentid="139" d="M-17.6,17.7C0.6,17.7,-2.5,-17.7,17.5,-17.7" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="220" transform="matrix(1,0,0,1,1381.05,483.04)" id="221" ed:parentid="139" d="M-17.6,0C-3.5,0,7,0,17.5,0" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="222" transform="matrix(1,0,0,1,1381.05,500.76)" id="223" ed:parentid="139" d="M-17.6,-17.7C0.6,-17.7,-2.5,17.7,17.5,17.7" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="224" transform="matrix(1,0,0,1,1381.05,518.49)" id="225" ed:parentid="139" d="M-17.6,-35.5C4,-35.5,-10.5,35.5,17.5,35.5" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="226" transform="matrix(1,0,0,1,1321.05,642.48)" id="227" ed:parentid="145" d="M-17.5,26.6C2.4,26.6,-6.8,-26.6,17.5,-26.6" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="228" transform="matrix(1,0,0,1,1321.05,660.2)" id="229" ed:parentid="145" d="M-17.5,8.9C-1.4,8.9,2.2,-8.9,17.5,-8.9" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="230" transform="matrix(1,0,0,1,1321.05,677.93)" id="231" ed:parentid="145" d="M-17.5,-8.9C-1.4,-8.9,2.2,8.9,17.6,8.9" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="232" transform="matrix(1,0,0,1,1321.05,695.65)" id="233" ed:parentid="145" d="M-17.5,-26.6C2.4,-26.6,-6.8,26.6,17.5,26.6" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="234" transform="matrix(1,0,0,1,372.75,75.54)" id="235" ed:parentid="246" d="M17.5,26.6C-2.4,26.6,6.8,-26.6,-17.5,-26.6" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="236" transform="matrix(1,0,0,1,372.75,93.26)" id="237" ed:parentid="246" d="M17.5,8.9C1.4,8.9,-2.2,-8.9,-17.5,-8.9" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="238" transform="matrix(1,0,0,1,372.75,110.99)" id="252" ed:parentid="246" d="M17.5,-8.9C1.4,-8.9,-2.2,8.9,-17.5,8.9" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="253" transform="matrix(1,0,0,1,372.75,128.71)" id="254" ed:parentid="246" d="M17.5,-26.6C-2.4,-26.6,6.8,26.6,-17.5,26.6" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="255" transform="matrix(1,0,0,1,332.75,261.56)" id="256" ed:parentid="258" d="M17.5,44.3C-5.3,44.3,13.5,-44.3,-17.5,-44.3" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="257" transform="matrix(1,0,0,1,332.75,279.29)" id="260" ed:parentid="258" d="M17.5,26.6C-2.4,26.6,6.8,-26.6,-17.5,-26.6" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="261" transform="matrix(1,0,0,1,332.75,297.01)" id="262" ed:parentid="258" d="M17.6,8.9C1.4,8.9,-2.2,-8.9,-17.6,-8.9" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="263" transform="matrix(1,0,0,1,332.75,314.74)" id="267" ed:parentid="258" d="M17.6,-8.9C1.4,-8.9,-2.2,8.9,-17.6,8.9" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="268" transform="matrix(1,0,0,1,332.75,332.46)" id="269" ed:parentid="258" d="M17.6,-26.6C-2.4,-26.6,6.8,26.6,-17.6,26.6" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="276" transform="matrix(1,0,0,1,332.75,350.19)" id="277" ed:parentid="258" d="M17.6,-44.3C-5.3,-44.3,13.5,44.3,-17.6,44.3" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="278" transform="matrix(1,0,0,1,392.75,500.76)" id="279" ed:parentid="157" d="M17.5,44.3C-5.3,44.3,13.5,-44.3,-17.5,-44.3" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="280" transform="matrix(1,0,0,1,392.75,518.49)" id="281" ed:parentid="157" d="M17.5,26.6C-2.4,26.6,6.8,-26.6,-17.5,-26.6" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="282" transform="matrix(1,0,0,1,392.75,536.21)" id="283" ed:parentid="157" d="M17.5,8.9C1.4,8.9,-2.2,-8.9,-17.5,-8.9" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="284" transform="matrix(1,0,0,1,392.75,553.94)" id="285" ed:parentid="157" d="M17.5,-8.9C1.4,-8.9,-2.2,8.9,-17.5,8.9" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="286" transform="matrix(1,0,0,1,392.75,571.66)" id="287" ed:parentid="157" d="M17.5,-26.6C-2.4,-26.6,6.8,26.6,-17.5,26.6" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="288" transform="matrix(1,0,0,1,392.75,589.39)" id="289" ed:parentid="157" d="M17.5,-44.3C-5.3,-44.3,13.5,44.3,-17.5,44.3" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="290" transform="matrix(1,0,0,1,372.75,722.24)" id="291" ed:parentid="243" d="M17.5,26.6C-2.4,26.6,6.8,-26.6,-17.5,-26.6" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="292" transform="matrix(1,0,0,1,372.75,739.96)" id="293" ed:parentid="243" d="M17.5,8.9C1.4,8.9,-2.2,-8.9,-17.5,-8.9" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="294" transform="matrix(1,0,0,1,372.75,757.69)" id="295" ed:parentid="243" d="M17.5,-8.9C1.4,-8.9,-2.2,8.9,-17.5,8.9" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <path ed:tosuperid="296" transform="matrix(1,0,0,1,372.75,775.41)" id="297" ed:parentid="243" d="M17.5,-26.6C-2.4,-26.6,6.8,26.6,-17.5,26.6" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none" stroke-linecap="round"/>
    <g transform="matrix(1,0,0,1,690.3,239.78)" ed:width="293.2" ed:layout="map" ed:topictype="mainidea" id="101" ed:height="371.4">
        <path d="M4,0L289.2,0C291.9,0,293.2,1.3,293.2,4L293.2,367.4C293.2,370.1,291.9,371.4,289.2,371.4L4,371.4C1.3,371.4,0,370.1,0,367.4L0,4C0,1.3,1.3,0,4,0z" stroke="#ffffff" stroke-width="4" stroke-linejoin="round" fill="#ffffff"/>
        <image width="247.2" xlink:href="" height="338.4" x="17" id="shape5" y="15"/>
        <text class="st45"/>
    </g>
    <g transform="matrix(1,0,0,1,1046.5,143.54)" ed:width="197" ed:layout="rightmap" id="122" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L197,38.4" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第一章原子结构</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/cgQXlTZXjAuE&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(164,11)"/>
        </g>
    </g>
    <symbol id="imghyperlink">
        <image width="16" xlink:href="" height="16"/>
    </symbol>
    <g transform="matrix(1,0,0,1,1046.5,444.69)" ed:width="317" ed:layout="rightmap" id="139" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L317,38.4" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第三章宏观物质及其聚集状态</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/csXdlBmgek89&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(284,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,1046.5,630.71)" ed:width="257" ed:layout="rightmap" id="145" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L257,38.4" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第四章化学热力学基础</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/cm1Vq5ljQdZL&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(224,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,1046.5,276.39)" ed:width="197" ed:layout="rightmap" id="147" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L197,38.4" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第二章分子结构</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/cnQGVPffrY6h&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(164,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,390.3,63.78)" ed:width="237" ed:layout="leftmap" id="246" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L237,38.4" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第五章化学反应平衡</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/cp1hpsKQxpHR&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(204,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,350.3,267.53)" ed:width="277" ed:layout="leftmap" id="258" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L277,38.4" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第六章水溶液的离子平衡</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/caDpAlfy5Z1Q&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(244,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,410.3,506.73)" ed:width="217" ed:layout="leftmap" id="157" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L217,38.4" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第七章电化学基础</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/cpajx0s7xFRL&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(184,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,390.3,710.48)" ed:width="237" ed:layout="leftmap" id="243" ed:parentid="101" ed:height="38.35">
        <path d="M0,38.4L237,38.4" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st46">
            <tspan style="white-space:pre" x="17" y="27.4">第八章化学反应速率</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://kdocs.cn/l/cnSZWxvpr2g4&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(204,11)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,1399.75,49.17)" ed:width="133.6" ed:layout="rightmap" ed:topictype="floating" id="270" ed:height="39.2">
        <path d="M4,0L129.6,0C132.3,0,133.6,1.3,133.6,4L133.6,35.2C133.6,37.9,132.3,39.2,129.6,39.2L4,39.2C1.3,39.2,0,37.9,0,35.2L0,4C0,1.3,1.3,0,4,0z" stroke="#a98ae7" stroke-linejoin="round" fill="#a98ae7"/>
        <text class="st47">
            <tspan style="white-space:pre" x="18" y="26.9">思维导图</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://duanjinyi.gitee.io/atomic-structure/&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(99,12)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,1562.99,226.11)" ed:width="133.6" ed:layout="rightmap" ed:topictype="floating" id="272" ed:height="39.2">
        <path d="M4,0L129.6,0C132.3,0,133.6,1.3,133.6,4L133.6,35.2C133.6,37.9,132.3,39.2,129.6,39.2L4,39.2C1.3,39.2,0,37.9,0,35.2L0,4C0,1.3,1.3,0,4,0z" stroke="#a98ae7" stroke-linejoin="round" fill="#a98ae7"/>
        <text class="st47">
            <tspan style="white-space:pre" x="18" y="26.9">思维导图</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://duanjinyi.gitee.io/molecular-structure/&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(99,12)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,1606,355.34)" ed:width="133.6" ed:layout="rightmap" ed:topictype="floating" id="274" ed:height="39.2">
        <path d="M4,0L129.6,0C132.3,0,133.6,1.3,133.6,4L133.6,35.2C133.6,37.9,132.3,39.2,129.6,39.2L4,39.2C1.3,39.2,0,37.9,0,35.2L0,4C0,1.3,1.3,0,4,0z" stroke="#a98ae7" stroke-linejoin="round" fill="#a98ae7"/>
        <text class="st47">
            <tspan style="white-space:pre" x="18" y="26.9">思维导图</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://duanjinyi.gitee.io/material-aggregation-state/&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(99,12)"/>
        </g>
    </g>
    <g transform="matrix(1,0,0,1,1278.6,117.49)" ed:width="194" ed:layout="rightmap" id="204" ed:parentid="122" ed:height="28.95">
        <path d="M0,29L194,29" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">近代原子结构发展历程</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1278.6,152.94)" ed:width="158.8" ed:layout="rightmap" id="206" ed:parentid="122" ed:height="28.95">
        <path d="M0,29L158.8,29" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">现代原子结构模型</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1278.6,188.39)" ed:width="246.8" ed:layout="rightmap" id="208" ed:parentid="122" ed:height="28.95">
        <path d="M0,29L246.8,29" stroke="#ff7575" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">多电子原子轨道能级与周期性</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1278.6,250.34)" ed:width="70.8" ed:layout="rightmap" id="210" ed:parentid="147" ed:height="28.95">
        <path d="M0,29L70.8,29" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">离子键</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1278.6,285.79)" ed:width="158.8" ed:layout="rightmap" id="212" ed:parentid="147" ed:height="28.95">
        <path d="M0,29L158.8,29" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">共价键与分子构型</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1278.6,321.24)" ed:width="176.4" ed:layout="rightmap" id="214" ed:parentid="147" ed:height="28.95">
        <path d="M0,29L176.4,29" stroke="#5fb7f1" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">配位键与配位化合物</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1398.6,383.19)" ed:width="176.4" ed:layout="rightmap" id="216" ed:parentid="139" ed:height="28.95">
        <path d="M0,29L176.4,29" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">分子间作用力与氢键</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1398.6,418.64)" ed:width="53.2" ed:layout="rightmap" id="218" ed:parentid="139" ed:height="28.95">
        <path d="M0,29L53.2,29" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">气体</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1398.6,454.09)" ed:width="53.2" ed:layout="rightmap" id="220" ed:parentid="139" ed:height="28.95">
        <path d="M0,29L53.2,29" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">液体</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1398.6,489.54)" ed:width="53.2" ed:layout="rightmap" id="222" ed:parentid="139" ed:height="28.95">
        <path d="M0,29L53.2,29" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">溶液</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1398.6,524.99)" ed:width="123.6" ed:layout="rightmap" id="224" ed:parentid="139" ed:height="28.95">
        <path d="M0,29L123.6,29" stroke="#ffcd55" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">晶体与非晶体</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1338.6,586.94)" ed:width="282" ed:layout="rightmap" id="226" ed:parentid="145" ed:height="28.95">
        <path d="M0,29L282,29" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">热力学的基本概念热力学第一定律</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1338.6,622.39)" ed:width="123.6" ed:layout="rightmap" id="228" ed:parentid="145" ed:height="28.95">
        <path d="M0,29L123.6,29" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">焓与盖斯定律</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1338.6,657.84)" ed:width="141.2" ed:layout="rightmap" id="230" ed:parentid="145" ed:height="28.95">
        <path d="M0,29L141.2,29" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">热力学第二定律</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1338.6,693.29)" ed:width="299.6" ed:layout="rightmap" id="232" ed:parentid="145" ed:height="28.95">
        <path d="M0,29L299.6,29" stroke="#f1a3dc" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">吉布斯函数与化学反应自发性的判据</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,126,20)" ed:width="229.2" ed:layout="leftmap" id="234" ed:parentid="246" ed:height="28.95">
        <path d="M0,29L229.2,29" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">化学平衡标准平衡常数概述</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,108.4,55.45)" ed:width="246.8" ed:layout="leftmap" id="236" ed:parentid="246" ed:height="28.95">
        <path d="M0,29L246.8,29" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">非标态下反应的吉布斯函数变</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,178.8,90.9)" ed:width="176.4" ed:layout="leftmap" id="238" ed:parentid="246" ed:height="28.95">
        <path d="M0,29L176.4,29" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">标准平衡常数的应用</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,214,126.35)" ed:width="141.2" ed:layout="leftmap" id="253" ed:parentid="246" ed:height="28.95">
        <path d="M0,29L141.2,29" stroke="#a98ae7" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">化学平衡的移动</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,156.4,188.3)" ed:width="158.8" ed:layout="leftmap" id="255" ed:parentid="258" ed:height="28.95">
        <path d="M0,29L158.8,29" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">强电解质溶液理论</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,191.6,223.75)" ed:width="123.6" ed:layout="leftmap" id="257" ed:parentid="258" ed:height="28.95">
        <path d="M0,29L123.6,29" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">酸碱理论简介</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,22,259.2)" ed:width="293.2" ed:layout="leftmap" id="261" ed:parentid="258" ed:height="28.95">
        <path d="M0,29L293.2,29" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">单相离子平衡--弱酸、弱碱解离平衡</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,86,294.65)" ed:width="229.2" ed:layout="leftmap" id="263" ed:parentid="258" ed:height="28.95">
        <path d="M0,29L229.2,29" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">难溶电解质的沉淀溶解平衡</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,226.8,330.1)" ed:width="88.40000000000001" ed:layout="leftmap" id="268" ed:parentid="258" ed:height="28.95">
        <path d="M0,29L88.4,29" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">配位平衡</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,174,365.55)" ed:width="141.2" ed:layout="leftmap" id="276" ed:parentid="258" ed:height="28.95">
        <path d="M0,29L141.2,29" stroke="#fa8556" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">氧化还原平衡…</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,269.2,427.5)" ed:width="106" ed:layout="leftmap" id="278" ed:parentid="157" ed:height="28.95">
        <path d="M0,29L106,29" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">电化学简介</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,304.4,462.95)" ed:width="70.8" ed:layout="leftmap" id="280" ed:parentid="157" ed:height="28.95">
        <path d="M0,29L70.8,29" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">原电池</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,286.8,498.4)" ed:width="88.40000000000001" ed:layout="leftmap" id="282" ed:parentid="157" ed:height="28.95">
        <path d="M0,29L88.4,29" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">电极电势</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,251.6,533.85)" ed:width="123.6" ed:layout="leftmap" id="284" ed:parentid="157" ed:height="28.95">
        <path d="M0,29L123.6,29" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">原电池热力学</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,198.8,569.3)" ed:width="176.4" ed:layout="leftmap" id="286" ed:parentid="157" ed:height="28.95">
        <path d="M0,29L176.4,29" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">电极电势的影响因素</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,234,604.75)" ed:width="141.2" ed:layout="leftmap" id="288" ed:parentid="157" ed:height="28.95">
        <path d="M0,29L141.2,29" stroke="#80cf70" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">电极电势的应用</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,302,666.7)" ed:width="53.2" ed:layout="leftmap" id="290" ed:parentid="243" ed:height="28.95">
        <path d="M0,29L53.2,29" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">概述</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,126,702.15)" ed:width="229.2" ed:layout="leftmap" id="292" ed:parentid="243" ed:height="28.95">
        <path d="M0,29L229.2,29" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">浓度对化学反应速率的影响</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,126,737.6)" ed:width="229.2" ed:layout="leftmap" id="294" ed:parentid="243" ed:height="28.95">
        <path d="M0,29L229.2,29" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">温度对化学反应速率的影响</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,108.4,773.05)" ed:width="246.8" ed:layout="leftmap" id="296" ed:parentid="243" ed:height="28.95">
        <path d="M0,29L246.8,29" stroke="#6cc9e5" stroke-width="2" stroke-linejoin="round" fill="none"/>
        <text class="st48">
            <tspan style="white-space:pre" x="8" y="21.4">催化剂对化学反应速率的影响</tspan>
        </text>
    </g>
    <g transform="matrix(1,0,0,1,1606,532.74)" ed:width="133.6" ed:layout="rightmap" ed:topictype="floating" id="298" ed:height="39.2">
        <path d="M4,0L129.6,0C132.3,0,133.6,1.3,133.6,4L133.6,35.2C133.6,37.9,132.3,39.2,129.6,39.2L4,39.2C1.3,39.2,0,37.9,0,35.2L0,4C0,1.3,1.3,0,4,0z" stroke="#a98ae7" stroke-linejoin="round" fill="#a98ae7"/>
        <text class="st47">
            <tspan style="white-space:pre" x="18" y="26.9">思维导图</tspan>
        </text>
        <g ed:hyperlink="[&#xa;    {&#xa;        &quot;desc&quot;: &quot;&quot;,&#xa;        &quot;link&quot;: &quot;https://duanjinyi.gitee.io/chemical-thermodynamics/&quot;&#xa;    }&#xa;]&#xa;">
            <use xlink:href="#imghyperlink" transform="translate(99,12)"/>
        </g>
    </g>
</svg>
</div>
        <div id="copyright">Created With  <a href="https://www.edrawsoft.com/" target="_blank" title="edrawsoft">MindMaster</a></div>
      </div>
    </div>
    <script>eval(atob('dmFyIG11YSA9IHdpbmRvdy5uYXZpZ2F0b3IudXNlckFnZW50Ow0KdmFyIHVhID0gKG11YS5pbmRleE9mKCdydjoxMScpICsgbXVhLmluZGV4T2YoJ01TSUUnKSkgPj0gMD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3RleHQnKTsNCiAgICAgICAgICAgIG4uc2V0QXR0cmlidXRlKCd4JywgNSk7DQogICAgICAgICAgICBuLnNldEF0dHJpYnV0ZSgneScsIDEyKTsNCiAgICAgICAgICAgIG4uc2V0QXR0cmlidXRlKCdmaWxsJywgJyMwMDZlZmYnKTsNCiAgICAgICAgICAgIG4udGV4dENvbnRlbnQgPSBuYW1lICsgJzogJzsNCiAgICAgICAgICAgIG4uc2V0QXR0cmlidXRlKCdmb250LXNpemUnLCAnMTInKTsNCiAgICAgICAgICAgIHQuc2V0QXR0cmlidXRlKCd4JywgMjAwKTsNCiAgICAgICAgICAgIHQuc2V0QXR0cmlidXRlKCd5JywgMTIpOw0KICAgICAgICAgICAgdC5zZXRBdHRyaWJ1dGUoJ2ZpbGwnLCAnIzk2OTY5NicpOw0KICAgICAgICAgICAgdC50ZXh0Q29udGVudCA9IHRpbWU7DQogICAgICAgICAgICB0LnNldEF0dHJpYnV0ZSgnZm9udC1zaXplJywgJzEwJyk7DQogICAgICAgICAgICBtLnNldEF0dHJpYnV0ZSgndHJhbnNmb3JtJywgJ3RyYW5zbGF0ZSgyMCwyNyknKTsNCiAgICAgICAgICAgIG0uc2V0QXR0cmlidXRlKCdmb250LXNpemUnLCAnMTInKTsNCiAgICAgICAgICAgIGZvciAodmFyIGsgPSAwOyBrIDwgbWVzc2FnZUFyci5sZW5ndGg7IGsrKykgew0KICAgICAgICAgICAgICAgIHZhciB0cyA9IGRvY3VtZW50LmNyZWF0ZUVsZW1lbnROUygnaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnLCAndHNwYW4nKTsNCiAgICAgICAgICAgICAgICB0cy5zZXRBdHRyaWJ1dGUoJ3gnLCAnMCcpOw0KICAgICAgICAgICAgICAgIHRzLnNldEF0dHJpYnV0ZSgneScsIGsgKiAxNik7DQogICAgICAgICAgICAgICAgdHMudGV4dENvbnRlbnQgPSBtZXNzYWdlQXJyW2tdOw0KICAgICAgICAgICAgICAgIG0uYXBwZW5kQ2hpbGQodHMpOw0KICAgICAgICAgICAgfQ0KICAgICAgICAgICAgby5zZXRBdHRyaWJ1dGUoJ3RyYW5zZm9ybScsICd0cmFuc2xhdGUoMCwnICsgaGVpZ2h0ICsgJyknKTsNCiAgICAgICAgICAgIG8uYXBwZW5kQ2hpbGQobik7DQogICAgICAgICAgICBvLmFwcGVuZENoaWxkKHQpOw0KICAgICAgICAgICAgby5hcHBlbmRDaGlsZChtKTsNCiAgICAgICAgICAgIGNhcnIucHVzaChvKTsNCiAgICAgICAgICAgIHBvcHVwLmFwcGVuZENoaWxkKG8pOw0KICAgICAgICAgICAgaGVpZ2h0ID0gKG1lc3NhZ2VBcnIubGVuZ3RoICsgMSkgKiAxNiArIGhlaWdodDsNCiAgICAgICAgfQ0KICAgICAgICB2YXIgd2FyciA9IGdldGN3aChwb3B1cCk7DQogICAgICAgIG9saW5lLnNldEF0dHJpYnV0ZSgneCcsICcwJyk7DQogICAgICAgIG9saW5lLnNldEF0dHJpYnV0ZSgneScsICcwJyk7DQogICAgICAgIHZhciBvdyA9IHdhcnJbMF0gKyAxMC41Ow0KICAgICAgICB2YXIgb2ggPSB3YXJyWzFdICsgMzsNCiAgICAgICAgb2xpbmUuc2V0QXR0cmlidXRlKCd3aWR0aCcsIG93KTsNCiAgICAgICAgb2xpbmUuc2V0QXR0cmlidXRlKCdoZWlnaHQnLCBvaCk7DQogICAgICAgIG9saW5lLnNldEF0dHJpYnV0ZSgnZmlsbCcsICd3aGl0ZScpOw0KICAgICAgICBvbGluZS5zZXRBdHRyaWJ1dGUoJ3N0cm9rZScsICcjNjU2NTY1Jyk7DQogICAgICAgIHBvcHVwLmFwcGVuZENoaWxkKG9saW5lKTsNCiAgICAgICAgdmFyIGwgPSBjYXJyLmxlbmd0aDsNCiAgICAgICAgd2hpbGUgKGwtLSkgew0KICAgICAgICAgICAgcG9wdXAuYXBwZW5kQ2hpbGQoY2FycltsXSk7DQogICAgICAgIH0NCiAgICAgICAgcG9wdXAub25tb3VzZW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XGQrKFwuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pXCkkLyk7DQogICAgICAgICAgICB2YXIgbWFBcnIgPSBbcGFyc2VGbG9hdChwcHNbMV0pLCBwYXJzZUZsb2F0KHBwc1szXSksIHBhcnNlRmxvYXQocHBzWzVdKSwgcGFyc2VGbG9hdChwcHNbN10pLCBwYXJzZUZsb2F0KHBwc1s5XSksIHBhcnNlRmxvYXQocHBzWzExXSldOw0KICAgICAgICAgICAgaWYgKG1hQXJyWzFdID09IDApIHsNCiAgICAgICAgICAgICAgICB2YXIgeCA9IHBhcnNlRmxvYXQoY3NbMF0pOw0KICAgICAgICAgICAgICAgIHZhciB5ID0gcGFyc2VGbG9hdChjc1sxXSkgKyAxNjsNCiAgICAgICAgICAgICAgICB2YXIgeDEgPSB4ICogbWFBcnJbMF0gKyB5ICogbWFBcnJbMl0gKyBtYUFycls0XTsNCiAgICAgICAgICAgICAgICB2YXIgeTEgPSB4ICogbWFBcnJbMV0gKyB5ICogbWFBcnJbM10gKyBtYUFycls1XTsNCiAgICAgICAgICAgICAgICB4MSA9IHgxLnRvc3VpdHN2ZygpOw0KICAgICAgICAgICAgICAgIHkxID0geTEudG9zdWl0c3ZnKCk7DQogICAgICAgICAgICAgICAgdmFyIHRyc3RyID0gJ3RyYW5zbGF0ZSgnICsgeDEgKyAnLCcgKyB5MSArICcpJzsNCiAgICAgICAgICAgIH0gZWxzZSB7DQogICAgICAgICAgICAgICAgdmFyIHggPSBwYXJzZUZsb2F0KGNzWzBdKSArIDE2Ow0KICAgICAgICAgICAgICAgIHZhciB5ID0gcGFyc2VGbG9hdChjc1sxXSkgKyAxNjsNCiAgICAgICAgICAgICAgICB2YXIgeDEgPSB4ICogbWFBcnJbMF0gKyB5ICogbWFBcnJbMl0gKyBtYUFycls0XTsNCiAgICAgICAgICAgICAgICB2YXIgeTEgPSB4ICogbWFBcnJbMV0gKyB5ICogbWFBcnJbM10gKyBtYUFycls1XTsNCiAgICAgICAgICAgICAgICB4ID0gcGFyc2VGbG9hdChjc1swXSkgKyAxNjsNCiAgICAgICAgICAgICAgICB5ID0gcGFyc2VGbG9hdChjc1sxXSk7DQogICAgICAgICAgICAgICAgdmFyIHgyID0geCAqIG1hQXJyWzBdICsgeSAqIG1hQXJyWzJdICsgbWFBcnJbNF07DQogICAgICAgICAgICAgICAgdmFyIHkyID0geCAqIG1hQXJyWzFdICsgeSAqIG1hQXJyWzNdICsgbWFBcnJbNV07DQogICAgICAgICAgICAgICAgdmFyIGZ4ID0geDEgPCB4MiA/IHgxLnRvc3VpdHN2ZygpIDogeDIudG9zdWl0c3ZnKCk7DQogICAgICAgICAgICAgICAgdmFyIGZ5ID0geTEgPiB5MiA/IHkxLnRvc3VpdHN2ZygpIDogeTIudG9zdWl0c3ZnKCk7DQogICAgICAgICAgICAgICAgdmFyIG9mZnkgPSBNYXRoLmFicyh5MSAtIHkyKTsNCiAgICAgICAgICAgICAgICB2YXIgdHJzdHIgPSAndHJhbnNsYXRlKCcgKyBmeCArICcsJyArIGZ5ICsgJyknOw0KICAgICAgICAgICAgICAgIHBvcHVwUi5zZXRBdHRyaWJ1dGUoJ2hlaWdodCcsIG9mZnkudG9TdHJpbmcoKSk7DQogICAgICAgICAgICAgICAgcG9wdXBSLnNldEF0dHJpYnV0ZSgnd2lkdGgnLCAnMTYnKTsNCiAgICAgICAgICAgICAgICBwb3B1cFIuc2V0QXR0cmlidXRlKCd5JywgKC1vZmZ5KS50b1N0cmluZygpKTsNCiAgICAgICAgICAgICAgICBwb3B1cFIuc2V0QXR0cmlidXRlKCdmaWxsJywgJ3RyYW5zcGFyZW50Jyk7DQogICAgICAgICAgICAgICAgcG9wdXAuYXBwZW5kQ2hpbGQocG9wdXBSKTsNCiAgICAgICAgICAgIH0NCiAgICAgICAgfQ0KICAgICAgICBwb3B1cC5zZXRBdHRyaWJ1dGUoJ3RyYW5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bGwnOw0KICAgICAgICAgICAgcG9wdXAuc3R5bGUudGV4dEFsaWduID0gJ2xlZnQnOw0KICAgICAgICAgICAgb2xpbmUuc2V0QXR0cmlidXRlKCd4JywgJzAnKTsNCiAgICAgICAgICAgIG9saW5lLnNldEF0dHJpYnV0ZSgneScsICcwJyk7DQogICAgICAgICAgICBvbGluZS5zZXRBdHRyaWJ1dGUoJ3dpZHRoJywgd2hbMF0gKyAxNik7DQogICAgICAgICAgICBvbGluZS5zZXRBdHRyaWJ1dGUoJ2hlaWdodCcsIHdoWzFdICsgOCk7DQogICAgICAgICAgICBvbGluZS5zZXRBdHRyaWJ1dGUoJ3N0cm9rZScsICcjYTI3YTAwJyk7DQogICAgICAgICAgICBvbGluZS5zZXRBdHRyaWJ1dGUoJ2ZpbGwnLCAnI2ZmZTc5ZCcpOw0KICAgICAgICAgICAgb3V0LmFwcGVuZENoaWxkKG9saW5lKTsNCiAgICAgICAgICAgIG91dC5hcHBlbmRDaGlsZChwb3B1cCk7DQogICAgICAgICAgICBvdXQuc2V0QXR0cmlidXRlKCdub3RlJywgJycpOw0KICAgICAgICAgICAgb3V0LnN0eWxlLmRpc3BsYXkgPSAnbm9uZSc7DQogICAgICAgICAgICBsZXQgbm90ZWlkID0gbm90ZXNbaV0ucGFyZW50Tm9kZS5wYXJlbnROb2RlLmlkICsgIiwiICsgbm90ZXNbaV0ucGFyZW50Tm9kZS5pZDsNCiAgICAgICAgICAgIG91dC5zZXRBdHRyaWJ1dGUoJ2VkOm5vdGVpZCcsIG5vdGVpZCk7DQogICAgICAgICAgICBvdXQub25tb3VzZW92ZXIgPSBmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgdGhpcy5zdHlsZS5kaXNwbGF5ID0gJ2Jsb2NrJzsNCiAgICAgICAgICAgIH07DQogICAgICAgICAgICBvdXQub25tb3VzZW91dCA9IGZ1bmN0aW9uICgpIHsNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgd2luZG93LmdldFNlbGVjdG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wuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pW1wsIF0oXC0/XGQrKFwuXGQrKT8pXCkkLyk7DQogICAgICAgICAgICAgICAgdmFyIG1hQXJyID0gW3BhcnNlRmxvYXQocHBzWzFdKSwgcGFyc2VGbG9hdChwcHNbM10pLCBwYXJzZUZsb2F0KHBwc1s1XSksIHBhcnNlRmxvYXQocHBzWzddKSwgcGFyc2VGbG9hdChwcHNbOV0pLCBwYXJzZUZsb2F0KHBwc1sxMV0pXTsNCiAgICAgICAgICAgICAgICBpZiAobWFBcnJbMV0gPT0gMCkgew0KICAgICAgICAgICAgICAgICAgICB2YXIgeCA9IHBhcnNlRmxvYXQoY3NbMF0pOw0KICAgICAgICAgICAgICAgICAgICB2YXIgeSA9IHBhcnNlRmxvYXQoY3NbMV0pICsgMTY7DQogICAgICAgICAgICAgICAgICAgIHZhciB4MSA9IHggKiBtYUFyclswXSArIHkgKiBtYUFyclsyXSArIG1hQXJyWzRdOw0KICAgICAgICAgICAgICAgICAgICB2YXIgeTEgPSB4ICogbWFBcnJbMV0gKyB5ICogbWFBcnJbM10gKyBtYUFycls1XTsNCiAgICAgICAgICAgICAgICAgICAgeDEgPSB4MS50b3N1aXRzdmcoKTsNCiAgICAgICAgICAgICAgICAgICAgeTEgPSB5MS50b3N1aXRzdmcoKTsNCiAgICAgICAgICAgICAgICAgICAgdmFyIHRyc3RyID0gJ3RyYW5zbGF0ZSgnICsgeDEgKyAnLCcgKyB5MSArICcpJzsNCiAgICAgICAgICAgICAgICB9IGVsc2Ugew0KICAgICAgICAgICAgICAgICAgICB2YXIgeCA9IHBhcnNlRmxvYXQoY3NbMF0pICsgMTY7DQogICAgICAgICAgICAgICAgICAgIHZhciB5ID0gcGFyc2VGbG9hdChjc1sxXSkgKyAxNjsNCiAgICAgICAgICAgICAgICAgICAgdmFyIHgxID0geCAqIG1hQXJyWzBdICsgeSAqIG1hQXJyWzJdICsgbWFBcnJbNF07DQogICAgICAgICAgICAgICAgICAgIHZhciB5MSA9IHggKiBtYUFyclsxXSArIHkgKiBtYUFyclszXSArIG1hQXJyWzVdOw0KICAgICAgICAgICAgICAgICAgICB4ID0gcGFyc2VGbG9hdChjc1swXSkgKyAxNjsNCiAgICAgICAgICAgICAgICAgICAgeSA9IHBhcnNlRmxvYXQoY3NbMV0pOw0KICAgICAgICAgICAgICAgICAgICB2YXIgeDIgPSB4ICogbWFBcnJbMF0gKyB5ICogbWFBcnJbMl0gKyBtYUFycls0XTsNCiAgICAgICAgICAgICAgICAgICAgdmFyIHkyID0geCAqIG1hQXJyWzFdICsgeSAqIG1hQXJyWzNdICsgbWFBcnJbNV07DQogICAgICAgICAgICAgICAgICAgIHZhciBmeCA9IHgxIDwgeDIgPyB4MS50b3N1aXRzdmcoKSA6IHgyLnRvc3VpdHN2ZygpOw0KICAgICAgICAgICAgICAgICAgICB2YXIgZnkgPSB5MSA+IHkyID8geTEudG9zdWl0c3ZnKCkgOiB5Mi50b3N1aXRzdmcoKTsNCiAgICAgICAgICAgICAgICAgICAgdmFyIG9mZnkgPSBNYXRoLmFicyh5MSAtIHkyKTsNCiAgICAgICAgICAgICAgICAgICAgdmFyIHRyc3RyID0gJ3RyYW5zbGF0ZSgnICsgZnggKyAnLCcgKyBmeSArICcpJzsNCiAgICAgICAgICAgICAgICAgICAgcG9wdXBSLnNldEF0dHJpYnV0ZSgnaGVpZ2h0Jywgb2ZmeS50b1N0cmluZygpKTsNCiAgICAgICAgICAgICAgICAgICAgcG9wdXBSLnNldEF0dHJpYnV0ZSgnd2lkdGgnLCAnMTYnKTsNCiAgICAgICAgICAgICAgICAgICAgcG9wdXBSLnNldEF0dHJpYnV0ZSgneScsICgtb2ZmeSkudG9TdHJpbmcoKSk7DQogICAgICAgICAgICAgICAgICAgIHBvcHVwUi5zZXRBdHRyaWJ1dGUoJ2ZpbGwnLCAndHJhbnNwYXJlbnQ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ICAgICAgICAgICBpZiAobWFBcnJbMV0gPT0gMCkgew0KICAgICAgICAgICAgICAgIHZhciB4ID0gcGFyc2VGbG9hdChjc1swXSk7DQogICAgICAgICAgICAgICAgdmFyIHkgPSBwYXJzZUZsb2F0KGNzWzFdKSArIDE2Ow0KICAgICAgICAgICAgICAgIHZhciB4MSA9IHggKiBtYUFyclswXSArIHkgKiBtYUFyclsyXSArIG1hQXJyWzRdOw0KICAgICAgICAgICAgICAgIHZhciB5MSA9IHggKiBtYUFyclsxXSArIHkgKiBtYUFyclszXSArIG1hQXJyWzVdOw0KICAgICAgICAgICAgICAgIHgxID0geDEudG9zdWl0c3ZnKCk7DQogICAgICAgICAgICAgICAgeTEgPSB5MS50b3N1aXRzdmcoKTsNCiAgICAgICAgICAgICAgICB2YXIgdHJzdHIgPSAndHJhbnNsYXRlKCcgKyB4MSArICcsJyArIHkxICsgJyknOw0KICAgICAgICAgICAgfSBlbHNlIHsNCiAgICAgICAgICAgICAgICB2YXIgeCA9IHBhcnNlRmxvYXQoY3NbMF0pICsgMTY7DQogICAgICAgICAgICAgICAgdmFyIHkgPSBwYXJzZUZsb2F0KGNzWzFdKSArIDE2Ow0KICAgICAgICAgICAgICAgIHZhciB4MSA9IHggKiBtYUFyclswXSArIHkgKiBtYUFyclsyXSArIG1hQXJyWzRdOw0KICAgICAgICAgICAgICAgIHZhciB5MSA9IHggKiBtYUFyclsxXSArIHkgKiBtYUFyclszXSArIG1hQXJyWzVdOw0KICAgICAgICAgICAgICAgIHggPSBwYXJzZUZsb2F0KGNzWzBdKSArIDE2Ow0KICAgICAgICAgICAgICAgIHkgPSBwYXJzZUZsb2F0KGNzWzFdKTsNCiAgICAgICAgICAgICAgICB2YXIgeDIgPSB4ICogbWFBcnJbMF0gKyB5ICogbWFBcnJbMl0gKyBtYUFycls0XTsNCiAgICAgICAgICAgICAgICB2YXIgeTIgPSB4ICogbWFBcnJbMV0gKyB5ICogbWFBcnJbM10gKyBtYUFycls1XTsNCiAgICAgICAgICAgICAgICB2YXIgZnggPSB4MSA8IHgyID8geDEudG9zdWl0c3ZnKCkgOiB4Mi50b3N1aXRzdmcoKTsNCiAgICAgICAgICAgICAgICB2YXIgZnkgPSB5MSA+IHkyID8geTEudG9zdWl0c3ZnKCkgOiB5Mi50b3N1aXRzdmcoKTsNCiAgICAgICAgICAgICAgICB2YXIgb2ZmeSA9IE1hdGguYWJzKHkxIC0geTIpOw0KICAgICAgICAgICAgICAgIHZhciB0cnN0ciA9ICd0cmFuc2xhdGUoJyArIGZ4ICsgJywnICsgZnkgKyAnKSc7DQogICAgICAgICAgICAgICAgcG9wdXBSLnNldEF0dHJpYnV0ZSgnaGVpZ2h0Jywgb2ZmeS50b1N0cmluZygpKTsNCiAgICAgICAgICAgICAgICBwb3B1cFIuc2V0QXR0cmlidXRlKCd3aWR0aCcsICcxNicpOw0KICAgICAgICAgICAgICAgIHBvcHVwUi5zZXRBdHRyaWJ1dGUoJ3knLCAoLW9mZnkpLnRvU3RyaW5nKCkpOw0KICAgICAgICAgICAgICAgIHBvcHVwUi5zZXRBdHRyaWJ1dGUoJ2ZpbGwnLCAndHJhbnNwYXJlbnQnKTsNCiAgICAgICAgICAgICAgICBwb3B1cC5hcHBlbmRDaGlsZChwb3B1cFIpOw0KICAgICAgICAgICAgfQ0KICAgICAgICB9DQogICAgICAgIHZhciBhbCA9IGEubGVuZ3RoOw0KICAgICAgICBmb3IgKHZhciBqID0gMDsgaiA8IGFsOyBqKyspIHsNCiAgICAgICAgICAgIGxpbmthcnIucHVzaChhW2pdLmxpbmspOw0KICAgICAgICAgICAgZGVzY2Fyci5wdXNoKGFbal0uZGVzYyk7DQogICAgICAgIH0NCiAgICAgICAgcG9wdXAuc2V0QXR0cmlidXRlKCd0cmFuc2Zvcm0nLCB0cnN0cik7DQogICAgICAgIHZhciBtYXggPSBnZXRtYXhsZW4obGlua2FyciwgZGVzY2Fycik7DQogICAgICAgIGZvciAodmFyIGsgPSAwOyBrIDwgYWw7IGsrKykgew0KICAgICAgICAgICAgdmFyIGMgPSBkb2N1bWVudC5jcmVhdGVFbGVtZW50TlMoJ2h0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnJywgJ2EnKTsNCiAgICAgICAgICAgIHZhciBkID0gZG9jdW1lbnQuY3JlYXRlRWxlbWVudE5TKCdodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZycsICdyZWN0Jyk7DQogICAgICAgICAgICB2YXIgZSA9IGRvY3VtZW50LmNyZWF0ZUVsZW1lbnROUygnaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnLCAndGV4dCcpOw0KICAgICAgICAgICAgdmFyIGYgPSBkb2N1bWVudC5jcmVhdGVFbGVtZW50TlMoJ2h0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnJywgJ3RleHQnKTsNCiAgICAgICAgICAgIGlmIChpc05hTihsaW5rYXJyW2tdKSkgew0KICAgICAgICAgICAgICAgIGMuc2V0QXR0cmlidXRlTlMoImh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiwgInhsaW5rIiwgImh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiKTsNCiAgICAgICAgICAgICAgICBjLnNldEF0dHJpYnV0ZU5TKCJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiwgImhyZWYiLCBsaW5rYXJyW2tdKTsNCiAgICAgICAgICAgICAgICBjLnNldEF0dHJpYnV0ZSgndGFyZ2V0JywgJ19ibGFuaycpOw0KICAgICAgICAgICAgICAgIGUudGV4dENvbnRlbnQgPSBsaW5rYXJyW2tdOw0KICAgICAgICAgICAgfSBlbHNlIHsNCiAgICAgICAgICAgICAgICBlLnRleHRDb250ZW50ID0gJ1BhZ2UtJyArIGxpbmthcnJba107DQogICAgICAgICAgICAgICAgYy5zZXRBdHRyaWJ1dGVOUygiaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciLCAieGxpbmsiLCAiaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIpOw0KICAgICAgICAgICAgICAgIGMuc2V0QXR0cmlidXRlTlMoImh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiLCAiaHJlZiIsICIjIiArIGxpbmthcnJba10pOw0KICAgICAgICAgICAgfQ0KICAgICAgICAgICAgZC5zZXRBdHRyaWJ1dGUoJ3dpZHRoJywgbWF4ICsgMTApOw0KICAgICAgICAgICAgZC5zZXRBdHRyaWJ1dGUoJ2hlaWdodCcsICczMycpOw0KICAgICAgICAgICAgZC5zZXRBdHRyaWJ1dGUoJ3N0cm9rZScsICcjOTk5OTk5Jyk7DQogICAgICAgICAgICBkLnNldEF0dHJpYnV0ZSgnZmlsbCcsICd3aGl0ZScpOw0KICAgICAgICAgICAgZC5zZXRBdHRyaWJ1dGUoJ3knLCAzMyAqIGspOw0KICAgICAgICAgICAgZi50ZXh0Q29udGVudCA9IGRlc2NhcnJba107DQogICAgICAgICAgICBmLnN0eWxlLmZvbnRTaXplID0gJzEycHgnOw0KICAgICAgICAgICAgZi5zdHlsZS5mb250V2VpZ2h0ID0gJ2JvbGQnOw0KICAgICAgICAgICAgZi5zZXRBdHRyaWJ1dGUoJ3gnLCA1KTsNCiAgICAgICAgICAgIGYuc2V0QXR0cmlidXRlKCd5JywgMzMgKiBrICsgMTIpOw0KICAgICAgICAgICAgZS5zdHlsZS5mb250U2l6ZSA9ICcxMnB4JzsNCiAgICAgICAgICAgIGUuc2V0QXR0cmlidXRlKCd5JywgMzMgKiBrICsgMjgpOw0KICAgICAgICAgICAgZS5zZXRBdHRyaWJ1dGUoJ3gnLCA1KTsNCiAgICAgICAgICAgIGMuYXBwZW5kQ2hpbGQoZCk7DQogICAgICAgICAgICBjLmFwcGVuZENoaWxkKGYpOw0KICAgICAgICAgICAgYy5hcHBlbmRDaGlsZChlKTsNCiAgICAgICAgICAgIGMub25tb3VzZW92ZXIgPSBmdW5jdGlvbiAoKSB7DQogICAgICAgICAgICAgICAgdGhpcy5xdWVyeVNlbGVjdG9yKCdyZWN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B7DQogICAgICAgICAgICAgICAgZXh0cmFSZWxhW2luZGV4aWRdID0gew0KICAgICAgICAgICAgICAgICAgICBpZDogaW5kZXhpZCwNCiAgICAgICAgICAgICAgICAgICAgZnJvbWlkOiBpZCwNCiAgICAgICAgICAgICAgICAgICAgdG9pZDogdG9pZCwNCiAgICAgICAgICAgICAgICAgICAgaXNDOiBmYWxzZQ0KICAgICAgICAgICAgICAgIH07DQogICAgICAgICAgICB9DQogICAgICAgICAgICBvYmpbIm0iICsgaWRdLnJlbGFmcm9tW2luZGV4aWRdID0ge307DQogICAgICAgICAgICBvYmpbIm0iICsgaWRdLnJlbGFmcm9tLmRpc3BsYXkgPSBkb2N1bWVudC5nZXRFbGVtZW50QnlJZChpZCkuc3R5bGUuZGlzcGxheSAhPT0gJ25vbmUnID8gJ2Jsb2NrJyA6ICdub25lJzsNCiAgICAgICAgfQ0KICAgIH0NCiAgICBpZiAocmVsYXRvLmxlbmd0aCAhPT0gMCkgew0KICAgICAgICBvYmpbIm0iICsgaWRdLnJlbGF0byA9IHt9Ow0KICAgICAgICBmb3IgKHZhciBpID0gMDsgaSA8IHJlbGF0by5sZW5ndGg7IGkrKykgew0KICAgICAgICAgICAgdmFyIGluZGV4aWQgPSByZWxhdG9baV0uaWQ7DQogICAgICAgICAgICB2YXIgZnJvbWlkID0gZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoaW5kZXhpZCkuZ2V0QXR0cmlidXRlKCdlZDpmcm9taWQnKTsNCiAgICAgICAgICAgIGlmIChleHRyYVJlbGFbaW5kZXhpZF0gPT09IHVuZGVmaW5lZCkgew0KICAgICAgICAgICAgICAgIGV4dHJhUmVsYVtpbmRleGlkXSA9IHsNCiAgICAgICAgICAgICAgICAgICAgaWQ6IGluZGV4aWQsDQogICAgICAgICAgICAgICAgICAgIGZyb21pZDogZnJvbWlkLA0KICAgICAgICAgICAgICAgICAgICB0b2lkOiBpZCwNCiAgICAgICAgICAgICAgICAgICAgaXNDOiBmYWxzZQ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mlidXRlKCdlZDpwYXJlbnRpZCcpOw0KICAgIGlmICghcGFyZW50KSB7DQogICAgICAgIHJldHVybjsNCiAgICB9DQogICAgaWYgKHBhcmVudC5tYXRjaCgvXCwvKSkgew0KICAgICAgICBwYXJlbnQgPSBwYXJlbnQubWF0Y2goL1xkKyg/PVwsKS8pWzBdDQogICAgfQ0KICAgIGdldGNoYWluKHBhcmVudCk7DQp9DQpmdW5jdGlvbiBnZXRvYmooaWQpIHsNCiAgICBjaGFpbkFyciA9IFtdOw0KICAgIGdldGNoYWluKGlkKTsNCiAgICB2YXIgbWFpbiA9IGNoYWluQXJyWzBdOw0KICAgIGlmIChjaGFpbkFyci5sZW5ndGggPiAxKSB7DQogICAgICAgIHZhciBvYmogPSBkYXRhVHJlZVttYWluXTsNCiAgICAgICAgLy8gY29uc29sZS5sb2coY2hhaW5BcnIpOw0KICAgICAgICBmb3IgKHZhciBpID0gMTsgaSA8IGNoYWluQXJyLmxlbmd0aDsgaSsrKSB7DQogICAgICAgICAgICB2YXIgYSA9IGNoYWluQXJyW2ldOw0KICAgICAgICAgICAgZm9yICh2YXIgaiA9IDA7IGogPCBPYmplY3Qua2V5cyhvYmopLmxlbmd0aDsgaisrKSB7DQogICAgICAgICAgICAgICAgdmFyIGNvYmogPSBvYmpbT2JqZWN0LmtleXMob2JqKVtqXV1bYV07DQogICAgICAgICAgICAgICAgaWYgKGNvYmopIHsNCiAgICAgICAgICAgICAgICAgICAgb2JqID0gY29iajsNCiAgICAgICAgICAgICAgICAgICAgY29udGludWUNCiAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICB9DQogICAgICAgIH0NCiAgICAgICAgcmV0dXJuIG9iag0KICAgIH0gZWxzZSB7DQogICAgICAgIHZhciBvYmogPSBkYXRhVHJlZVttYWluXTsNCiAgICAgICAgcmV0dXJuIG9iag0KICAgIH0NCg0KfQ0KZm9yICh2YXIgaSA9IDA7IGkgPCBzaGFwZS5sZW5ndGg7IGkrKykgew0KICAgIHNoYXBlW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aysrKSB7DQogICAgICAgICAgICAgICAgdmFyIGQgPSByZWxhZnJvbXNba107DQogICAgICAgICAgICAgICAgZXh0cmFSZWxhW2RdLmlzQyA9IHRydWU7DQogICAgICAgICAgICB9DQogICAgICAgICAgICBvYmoucmVsYWZyb20uZGlzcGxheSA9IHBzaG93Ow0KICAgICAgICB9DQogICAgfQ0KICAgIGlmIChvYmoucmVsYXRvKSB7DQogICAgICAgIGlmIChvYmoucmVsYXRvLmRpc3BsYXkgIT09IHBzaG93KSB7DQogICAgICAgICAgICB2YXIgcmVsYXRvcyA9IE9iamVjdC5rZXlzKG9iai5yZWxhdG8pOw0KICAgICAgICAgICAgcmVsYXRvcy5zcGxpY2UocmVsYXRvcy5pbmRleE9mKCdkaXNwbGF5JyksIDEpOw0KICAgICAgICAgICAgZm9yICh2YXIgayA9IDA7IGsgPCByZWxhdG9zLmxlbmd0aDsgaysrKSB7DQogICAgICAgICAgICAgICAgdmFyIGQgPSByZWxhdG9zW2tdOw0KICAgICAgICAgICAgICAgIGV4dHJhUmVsYVtkXS5pc0MgPSB0cnVlOw0KICAgICAgICAgICAgfQ0KICAgICAgICAgICAgb2JqLnJlbGF0by5kaXNwbGF5ID0gcHNob3c7DQogICAgICAgIH0NCiAgICB9DQogICAgaWYgKG9iai5jYWxsKSB7DQogICAgICAgIHZhciBjYWxscyA9IE9iamVjdC5rZXlzKG9iai5jYWxsKTsNCiAgICAgICAgaWYgKGNoZWNrSUQgIT09IG9iaikgew0KICAgICAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBjYWxscy5sZW5ndGg7IGkrKykgew0KICAgICAgICAgICAgICAgIHZhciBhID0gY2FsbHNbaV0uc2xpY2UoMSk7DQogICAgICAgICAgICAgICAgdmFyIGIgPSBvYmouY2FsbFtjYWxsc1tpXV07DQogICAgICAgICAgICAgICAgdmFyIGMgPSBiLnRvZ3R5cGU7DQogICAgICAgICAgICAgICAgZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoYSkuc3R5bGUuZGlzcGxheSA9IHNob3c7DQogICAgICAgICAgICAgICAgaWYgKGIucmVsYWZyb20gJiYgIWMpIHsNCiAgICAgICAgICAgICAgICAgICAgaWYgKGIucmVsYWZyb20uZGlzcGxheSAhPT0gc2hvdykgew0KICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlbGFmcm9tcyA9IE9iamVjdC5rZXlzKGIucmVsYWZyb20pOw0KICAgICAgICAgICAgICAgICAgICAgICAgcmVsYWZyb21zLnNwbGljZShyZWxhZnJvbXMuaW5kZXhPZignZGlzcGxheScpLCAxKTsNCiAgICAgICAgICAgICAgICAgICAgICAgIGZvciAodmFyIGsgPSAwOyBrIDwgcmVsYWZyb21zLmxlbmd0aDsgaysrKSB7DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGQgPSByZWxhZnJvbXNba107DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgZXh0cmFSZWxhW2RdLmlzQyA9IHRydWU7DQogICAgICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgICAgICAgICBiLnJlbGFmcm9tLmRpc3BsYXkgPSBzaG93Ow0KICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIGlmIChiLnJlbGF0byAmJiAhYykgew0KICAgICAgICAgICAgICAgICAgICBpZiAoYi5yZWxhdG8uZGlzcGxheSAhPT0gc2hvdykgew0KICAgICAgICAgICAgICAgICAgICAgICAgdmFyIHJlbGF0b3MgPSBPYmplY3Qua2V5cyhiLnJlbGF0byk7DQogICAgICAgICAgICAgICAgICAgICAgICByZWxhdG9zLnNwbGljZShyZWxhdG9zLmluZGV4T2YoJ2Rpc3BsYXknKSwgMSk7DQogICAgICAgICAgICAgICAgICAgICAgICBmb3IgKHZhciBrID0gMDsgayA8IHJlbGF0b3MubGVuZ3RoOyBrKyspIHsNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YXIgZCA9IHJlbGF0b3Nba107DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgZXh0cmFSZWxhW2RdLmlzQyA9IHRydWU7DQogICAgICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgICAgICAgICBiLnJlbGF0by5kaXNwbGF5ID0gc2hvdzsNCiAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICBpZiAoYykgew0KICAgICAgICAgICAgICAgICAgICBkb2N1bWVudC5xdWVyeVNlbGVjdG9yKCJnW2VkXFw6dG9ndG9waWNpZD0nIiArIGEgKyAiJ10iKS5zdHlsZS5kaXNwbGF5ID0gc2hvdzsNCiAgICAgICAgICAgICAgICAgICAgaWYgKGMgPT09ICdtaW51cycpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIHV0ZChiLCBhLCBzaG93KQ0KICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgICAgIGlmICgoYi5jYWxsIHx8IGIuYm91bmRhcnkgfHwgYi5zdW1tYXJ5KSAmJiBjID09PSAncGx1cycpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIHV0ZChiLCBhLCBzaG93LCB0cnVlKQ0KICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIGlmIChiLmNhbGwgJiYgIWMpIHsNCiAgICAgICAgICAgICAgICAgICAgdXRkKGIsIGEsIHNob3csIHRydWUpDQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIGlmIChiLnN1bW1hcnkgJiYgIWMpIHsNCiAgICAgICAgICAgICAgICAgICAgdXRkKGIsIGEsIHNob3cpDQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIGlmIChiLmJvdW5kYXJ5ICYmICFjKSB7DQogICAgICAgICAgICAgICAgICAgIHV0ZChiLCBhLCBzaG93KQ0KICAgICAgICAgICAgICAgIH0NCg0KICAgICAgICAgICAgfQ0KICAgICAgICB9DQogICAgfQ0KICAgIGlmIChvYmouc3VtbWFyeSkgew0KICAgICAgICB2YXIgc3VtbWFyeXMgPSBPYmplY3Qua2V5cyhvYmouc3VtbWFyeSk7DQogICAgICAgIGlmICgoY2hlY2tJRCAhPT0gb2JqICYmIChvYmoudG9ndHlwZSA9PT0gJ21pbnVzJyB8fCAhb2JqLnRvZ3R5cGUpKSB8fCBjaGVja0lEID09PSBvYmopIHsNCiAgICAgICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgc3VtbWFyeXMubGVuZ3RoOyBpKyspIHsNCiAgICAgICAgICAgICAgICB2YXIgYSA9IHN1bW1hcnlzW2ldLnNsaWNlKDEpOw0KICAgICAgICAgICAgICAgIHZhciBvc3AgPSBkb2N1bWVudC5nZXRFbGVtZW50QnlJZChhKS5nZXRBdHRyaWJ1dGUoJ2VkOnBhcmVudGlkJyk7DQogICAgICAgICAgICAgICAgaWYgKG9zcC5tYXRjaCgvXCwvKSkgew0KICAgICAgICAgICAgICAgICAgICB2YXIgb3NwYSA9IG9zcC5zcGxpdCgnLCcpOw0KICAgICAgICAgICAgICAgICAgICB2YXIgb3NwTCA9IDA7DQoNCiAgICAgICAgICAgICAgICAgICAgZm9yICh2YXIgaiA9IDA7IGogPCBvc3BhLmxlbmd0aDsgaisrKSB7DQogICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2hvdyA9PSAnbm9uZScpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQob3NwYVtqXSkuc3R5bGUuZGlzcGxheSAhPSAnbm9uZScpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHsNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb3NwTCsrOw0KICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGRvY3VtZW50LmdldEVsZW1lbnRCeUlkKGEpLnN0eWxlLmRpc3BsYXkgIT0gJ25vbmUnKSB7DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrOw0KICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7DQogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG9zcEwrKzsNCiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgICAgICAgICB9DQoNCiAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgICAgICBpZiAob3NwTCAhPT0gb3NwYS5sZW5ndGgpIHsNCiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnRpbnVlOw0KICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIHZhciBiID0gb2JqLnN1bW1hcnlbc3VtbWFyeXNbaV1dOw0KICAgICAgICAgICAgICAgIC8vIGNvbnNvbGUubG9nKGEpOw0KICAgICAgICAgICAgICAgIGRvY3VtZW50LmdldEVsZW1lbnRCeUlkKGEpLnN0eWxlLmRpc3BsYXkgPSBzaG93Ow0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgIGlmKGMpew0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgICAgICBkb2N1bWVudC5xdWVyeVNlbGVjdG9yKCJnW2VkXFw6dG9ndG9waWNpZD0nIithKyInXSIpLnN0eWxlLmRpc3BsYXk9c2hvdzsNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICAgICAgaWYoYz09PSdtaW51cycpew0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgICAgICAgICAgdXRkKGIsc2hvdykNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgICAgICBpZiAoYi5jYWxsJiZjPT09J3BsdXMnKSB7DQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgICAgICAgICB1dGQoYixzaG93LHRydWUpDQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgaWYoYi5jYWxsJiYhYykgew0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgICAgICB1dGQoYixzaG93LHRydWUpDQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIGlmIChPYmplY3Qua2V5cyhiKS5sZW5ndGggIT09IDApIHsNCiAgICAgICAgICAgICAgICAgICAgdXRkKGIsIGEsIHNob3cpDQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgfQ0KICAgICAgICB9DQogICAgfQ0KICAgIGlmIChvYmouYm91bmRhcnkpIHsNCiAgICAgICAgdmFyIGJvdW5kYXJ5cyA9IE9iamVjdC5rZXlzKG9iai5ib3VuZGFyeSk7DQogICAgICAgIGlmIChjaGVja0lEICE9PSBvYmopIHsNCiAgICAgICAgICAgIGZvciAodmFyIGkgPSAwOyBpIDwgYm91bmRhcnlzLmxlbmd0aDsgaSsrKSB7DQogICAgICAgICAgICAgICAgdmFyIGEgPSBib3VuZGFyeXNbaV0uc2xpY2UoMSk7DQogICAgICAgICAgICAgICAgdmFyIGIgPSBvYmouYm91bmRhcnlbYm91bmRhcnlzW2ldXTsNCiAgICAgICAgICAgICAgICAvLyBjb25zb2xlLmxvZyhhKTsNCiAgICAgICAgICAgICAgICBkb2N1bWVudC5nZXRFbGVtZW50QnlJZChhKS5zdHlsZS5kaXNwbGF5ID0gc2hvdzsNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICBpZihjKXsNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICAgICAgZG9jdW1lbnQucXVlcnlTZWxlY3RvcigiZ1tlZFxcOnRvZ3RvcGljaWQ9JyIrYSsiJ10iKS5zdHlsZS5kaXNwbGF5PXNob3c7DQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgICAgIGlmKGM9PT0nbWludXMnKXsNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICAgICAgICAgIHV0ZChiLHNob3cpDQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICAgICAgaWYgKGIuY2FsbCYmYz09PSdwbHVzJykgew0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgICAgICAgICAgdXRkKGIsc2hvdyx0cnVlKQ0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgLy8gICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgIGlmKGIuY2FsbCYmIWMpIHsNCiAgICAgICAgICAgICAgICAvLyAgICAgICAgICAgICAgICAgICAgdXRkKGIsc2hvdyx0cnVlKQ0KICAgICAgICAgICAgICAgIC8vICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICBpZiAoT2JqZWN0LmtleXMoYikubGVuZ3RoICE9PSAwKSB7DQogICAgICAgICAgICAgICAgICAgIHV0ZChiLCBhLCBzaG93KQ0KICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgIH0NCiAgICAgICAgfQ0KICAgIH0NCiAgICBpZiAoIW9jICYmIG9iai5jaGlsZCkgew0KICAgICAgICB2YXIgY2hpbGRzID0gT2JqZWN0LmtleXMob2JqLmNoaWxkKTsNCiAgICAgICAgZm9yICh2YXIgaSA9IDA7IGkgPCBjaGlsZHMubGVuZ3RoOyBpKyspIHsNCiAgICAgICAgICAgIHZhciBhID0gY2hpbGRzW2ldLnNsaWNlKDEpOw0KICAgICAgICAgICAgdmFyIGIgPSBvYmouY2hpbGRbY2hpbGRzW2ldXTsNCiAgICAgICAgICAgIHZhciBjID0gYi50b2d0eXBlOw0KICAgICAgICAgICAgZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoYSkuc3R5bGUuZGlzcGxheSA9IHNob3c7DQogICAgICAgICAgICB2YXIgdFNQYXRoID0gZG9jdW1lbnQucXVlcnlTZWxlY3RvcigicGF0aFtlZFxcOnRvc3VwZXJpZD0nIiArIGEgKyAiJ10iKTsNCiAgICAgICAgICAgIGlmICh0U1BhdGgpIHsNCiAgICAgICAgICAgICAgICB0U1BhdGguc3R5bGUuZGlzcGxheSA9IHNob3c7DQogICAgICAgICAgICB9DQogICAgICAgICAgICB2YXIgbm90ZVRpcCA9IGRvY3VtZW50LnF1ZXJ5U2VsZWN0b3IoImdbZWRcXDpub3RldG89JyIgKyBhICsgIiddIik7DQogICAgICAgICAgICBpZiAobm90ZVRpcCkgew0KICAgICAgICAgICAgICAgIG5vdGVUaXAuc3R5bGUuZGlzcGxheSA9IHNob3c7DQogICAgICAgICAgICB9DQogICAgICAgICAgICBpZiAoYi5yZWxhZnJvbSAmJiAhYykgew0KICAgICAgICAgICAgICAgIGlmIChiLnJlbGFmcm9tLmRpc3BsYXkgIT09IHNob3cpIHsNCiAgICAgICAgICAgICAgICAgICAgdmFyIHJlbGFmcm9tcyA9IE9iamVjdC5rZXlzKGIucmVsYWZyb20pOw0KICAgICAgICAgICAgICAgICAgICByZWxhZnJvbXMuc3BsaWNlKHJlbGFmcm9tcy5pbmRleE9mKCdkaXNwbGF5JyksIDEpOw0KICAgICAgICAgICAgICAgICAgICBmb3IgKHZhciBrID0gMDsgayA8IHJlbGFmcm9tcy5sZW5ndGg7IGsrKykgew0KICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGQgPSByZWxhZnJvbXNba107DQogICAgICAgICAgICAgICAgICAgICAgICBleHRyYVJlbGFbZF0uaXNDID0gdHJ1ZTsNCiAgICAgICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgICAgICAgICBiLnJlbGFmcm9tLmRpc3BsYXkgPSBzaG93Ow0KICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgIH0NCiAgICAgICAgICAgIGlmIChiLnJlbGF0byAmJiAhYykgew0KICAgICAgICAgICAgICAgIGlmIChiLnJlbGF0by5kaXNwbGF5ICE9PSBzaG93KSB7DQogICAgICAgICAgICAgICAgICAgIHZhciByZWxhdG9zID0gT2JqZWN0LmtleXMoYi5yZWxhdG8pOw0KICAgICAgICAgICAgICAgICAgICByZWxhdG9zLnNwbGljZShyZWxhdG9zLmluZGV4T2YoJ2Rpc3BsYXknKSwgMSk7DQogICAgICAgICAgICAgICAgICAgIGZvciAodmFyIGsgPSAwOyBrIDwgcmVsYXRvcy5sZW5ndGg7IGsrKykgew0KICAgICAgICAgICAgICAgICAgICAgICAgdmFyIGQgPSByZWxhdG9zW2tdOw0KICAgICAgICAgICAgICAgICAgICAgICAgZXh0cmFSZWxhW2RdLmlzQyA9IHRydWU7DQogICAgICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICAgICAgYi5yZWxhdG8uZGlzcGxheSA9IHNob3c7DQogICAgICAgICAgICAgICAgfQ0KICAgICAgICAgICAgfQ0KICAgICAgICAgICAgaWYgKGMpIHsNCiAgICAgICAgICAgICAgICBkb2N1bWVudC5xdWVyeVNlbGVjdG9yKCJnW2VkXFw6dG9ndG9waWNpZD0nIiArIGEgKyAiJ10iKS5zdHlsZS5kaXNwbGF5ID0gc2hvdzsNCiAgICAgICAgICAgICAgICBpZiAoYyA9PT0gJ21pbnVzJykgew0KICAgICAgICAgICAgICAgICAgICB1dGQoYiwgYSwgc2hvdykNCiAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICAgICAgaWYgKChiLmNhbGwgfHwgYi5ib3VuZGFyeSB8fCBiLnN1bW1hcnkpICYmIGMgPT09ICdwbHVzJykgew0KICAgICAgICAgICAgICAgICAgICB1dGQoYiwgYSwgc2hvdywgdHJ1ZSkNCiAgICAgICAgICAgICAgICB9DQogICAgICAgICAgICB9DQogICAgICAgICAgICBpZiAoYi5jYWxsICYmICFjKSB7DQogICAgICAgICAgICAgICAgdXRkKGIsIGEsIHNob3csIHRydWUpDQogICAgICAgICAgICB9DQogICAgICAgICAgICBpZiAoYi5zdW1tYXJ5ICYmICFjKSB7DQogICAgICAgICAgICAgICAgdXRkKGIsIGEsIHNob3cpDQogICAgICAgICAgICB9DQogICAgICAgICAgICBpZiAoYi5ib3VuZGFyeSAmJiAhYykgew0KICAgICAgICAgICAgICAgIHV0ZChiLCBhLCBzaG93KQ0KICAgICAgICAgICAgfQ0KICAgICAgICB9DQogICAgfQ0KfQ0KDQpmdW5jdGlvbiBleHRyYVJlbGFGaW4oKSB7DQogICAgdmFyIGV4dHJha2V5cyA9IE9iamVjdC5rZXlzKGV4dHJhUmVsYSk7DQogICAgZm9yICh2YXIgaSA9IDA7IGkgPCBleHRyYWtleXMubGVuZ3RoOyBpKyspIHsNCiAgICAgICAgdmFyIGV4dHJhT2JqID0gZXh0cmFSZWxhW2V4dHJha2V5c1tpXV07DQogICAgICAgIGlmIChleHRyYU9iai5pc0MgPT09IHRydWUpIHsNCiAgICAgICAgICAgIHZhciBmc2hvdyA9IGRvY3VtZW50LmdldEVsZW1lbnRCeUlkKGV4dHJhT2JqLmZyb21pZCkuc3R5bGUuZGlzcGxheSAhPT0gJ25vbmUnID8gdHJ1ZSA6IGZhbHNlOw0KICAgICAgICAgICAgdmFyIHRzaG93ID0gZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoZXh0cmFPYmoudG9pZCkuc3R5bGUuZGlzcGxheSAhPT0gJ25vbmUnID8gdHJ1ZSA6IGZhbHNlOw0KICAgICAgICAgICAgZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoZXh0cmFPYmouaWQpLnN0eWxlLmRpc3BsYXkgPSBmc2hvdyAmJiB0c2hvdyA/ICdibG9jaycgOiAnbm9uZSc7DQogICAgICAgICAgICBleHRyYVJlbGFbZXh0cmFrZXlzW2ldXS5pc0MgPSBmYWxzZTsNCiAgICAgICAgfQ0KICAgIH0NCn0='))</script>
  </body>
</html>
